<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <h1 class="title">origin</h1>
    <script>
      // 子页面获取父页面数据
      window.person = {
        name: "jack",
      };
      // console.log(window.parent); // 父页面 window 对象
      // console.log(window.parent.document.querySelector("h1"));
    </script>
  </body>
</html>
